package com.afollestad.materialdialogs.internal;

import com.afollestad.materialdialogs.GravityEnum;
import ohos.agp.components.element.Element;

/**
 * Use of this is discouraged for now; for internal use only. See the Global Theming section of the
 * README.
 */
public class ThemeSingleton {
    private static final String TAG = ThemeSingleton.class.getSimpleName();
    private static ThemeSingleton singleton;
    public boolean darkTheme = false;
    public int titleColor = 0, contentColor = 0, positiveColor = 0, neutralColor = 0, negativeColor = 0, widgetColor = 0, linkColor = 0, itemColor = 0, listSelector = 0, backgroundColor = 0, dividerColor = 0, btnSelectorStacked = 0, btnSelectorPositive = 0, btnSelectorNeutral = 0, btnSelectorNegative = 0;
    public GravityEnum titleGravity = GravityEnum.START, contentGravity = GravityEnum.START, btnStackedGravity = GravityEnum.END, itemsGravity = GravityEnum.START, buttonsGravity = GravityEnum.START;
    public Element icon = null;

    public static ThemeSingleton get(boolean createIfNull) {
        if (singleton == null && createIfNull) {
            singleton = new ThemeSingleton();
        }
        return singleton;
    }

    public static ThemeSingleton get() {
        return get(true);
    }
}
